\(\int \frac {\sec ^2(c+d x)}{(a+i a \tan (c+d x))^8} \, dx\) [172]

   Optimal result
   Rubi [A] (verified)
   Mathematica [A] (verified)
   Maple [A] (verified)
   Fricas [B] (verification not implemented)
   Sympy [B] (verification not implemented)
   Maxima [A] (verification not implemented)
   Giac [B] (verification not implemented)
   Mupad [B] (verification not implemented)

Optimal result

Integrand size = 24, antiderivative size = 27 \[ \int \frac {\sec ^2(c+d x)}{(a+i a \tan (c+d x))^8} \, dx=\frac {i}{7 a d (a+i a \tan (c+d x))^7} \]

[Out]

1/7*I/a/d/(a+I*a*tan(d*x+c))^7

Rubi [A] (verified)

Time = 0.05 (sec) , antiderivative size = 27, normalized size of antiderivative = 1.00, number of steps used = 2, number of rules used = 2, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.083, Rules used = {3568, 32} \[ \int \frac {\sec ^2(c+d x)}{(a+i a \tan (c+d x))^8} \, dx=\frac {i}{7 a d (a+i a \tan (c+d x))^7} \]

[In]

Int[Sec[c + d*x]^2/(a + I*a*Tan[c + d*x])^8,x]

[Out]

(I/7)/(a*d*(a + I*a*Tan[c + d*x])^7)

Rule 32

Int[((a_.) + (b_.)*(x_))^(m_), x_Symbol] :> Simp[(a + b*x)^(m + 1)/(b*(m + 1)), x] /; FreeQ[{a, b, m}, x] && N
eQ[m, -1]

Rule 3568

Int[sec[(e_.) + (f_.)*(x_)]^(m_)*((a_) + (b_.)*tan[(e_.) + (f_.)*(x_)])^(n_), x_Symbol] :> Dist[1/(a^(m - 2)*b
*f), Subst[Int[(a - x)^(m/2 - 1)*(a + x)^(n + m/2 - 1), x], x, b*Tan[e + f*x]], x] /; FreeQ[{a, b, e, f, n}, x
] && EqQ[a^2 + b^2, 0] && IntegerQ[m/2]

Rubi steps \begin{align*} \text {integral}& = -\frac {i \text {Subst}\left (\int \frac {1}{(a+x)^8} \, dx,x,i a \tan (c+d x)\right )}{a d} \\ & = \frac {i}{7 a d (a+i a \tan (c+d x))^7} \\ \end{align*}

Mathematica [A] (verified)

Time = 0.21 (sec) , antiderivative size = 22, normalized size of antiderivative = 0.81 \[ \int \frac {\sec ^2(c+d x)}{(a+i a \tan (c+d x))^8} \, dx=-\frac {1}{7 a^8 d (-i+\tan (c+d x))^7} \]

[In]

Integrate[Sec[c + d*x]^2/(a + I*a*Tan[c + d*x])^8,x]

[Out]

-1/7*1/(a^8*d*(-I + Tan[c + d*x])^7)

Maple [A] (verified)

Time = 0.42 (sec) , antiderivative size = 24, normalized size of antiderivative = 0.89

method result size
derivativedivides \(\frac {i}{7 a d \left (a +i a \tan \left (d x +c \right )\right )^{7}}\) \(24\)
default \(\frac {i}{7 a d \left (a +i a \tan \left (d x +c \right )\right )^{7}}\) \(24\)
risch \(\frac {i {\mathrm e}^{-2 i \left (d x +c \right )}}{128 a^{8} d}+\frac {3 i {\mathrm e}^{-4 i \left (d x +c \right )}}{128 a^{8} d}+\frac {5 i {\mathrm e}^{-6 i \left (d x +c \right )}}{128 a^{8} d}+\frac {5 i {\mathrm e}^{-8 i \left (d x +c \right )}}{128 a^{8} d}+\frac {3 i {\mathrm e}^{-10 i \left (d x +c \right )}}{128 a^{8} d}+\frac {i {\mathrm e}^{-12 i \left (d x +c \right )}}{128 a^{8} d}+\frac {i {\mathrm e}^{-14 i \left (d x +c \right )}}{896 a^{8} d}\) \(128\)

[In]

int(sec(d*x+c)^2/(a+I*a*tan(d*x+c))^8,x,method=_RETURNVERBOSE)

[Out]

1/7*I/a/d/(a+I*a*tan(d*x+c))^7

Fricas [B] (verification not implemented)

Both result and optimal contain complex but leaf count of result is larger than twice the leaf count of optimal. 85 vs. \(2 (21) = 42\).

Time = 0.23 (sec) , antiderivative size = 85, normalized size of antiderivative = 3.15 \[ \int \frac {\sec ^2(c+d x)}{(a+i a \tan (c+d x))^8} \, dx=\frac {{\left (7 i \, e^{\left (12 i \, d x + 12 i \, c\right )} + 21 i \, e^{\left (10 i \, d x + 10 i \, c\right )} + 35 i \, e^{\left (8 i \, d x + 8 i \, c\right )} + 35 i \, e^{\left (6 i \, d x + 6 i \, c\right )} + 21 i \, e^{\left (4 i \, d x + 4 i \, c\right )} + 7 i \, e^{\left (2 i \, d x + 2 i \, c\right )} + i\right )} e^{\left (-14 i \, d x - 14 i \, c\right )}}{896 \, a^{8} d} \]

[In]

integrate(sec(d*x+c)^2/(a+I*a*tan(d*x+c))^8,x, algorithm="fricas")

[Out]

1/896*(7*I*e^(12*I*d*x + 12*I*c) + 21*I*e^(10*I*d*x + 10*I*c) + 35*I*e^(8*I*d*x + 8*I*c) + 35*I*e^(6*I*d*x + 6
*I*c) + 21*I*e^(4*I*d*x + 4*I*c) + 7*I*e^(2*I*d*x + 2*I*c) + I)*e^(-14*I*d*x - 14*I*c)/(a^8*d)

Sympy [B] (verification not implemented)

Both result and optimal contain complex but leaf count of result is larger than twice the leaf count of optimal. 1081 vs. \(2 (19) = 38\).

Time = 8.89 (sec) , antiderivative size = 1081, normalized size of antiderivative = 40.04 \[ \int \frac {\sec ^2(c+d x)}{(a+i a \tan (c+d x))^8} \, dx=\text {Too large to display} \]

[In]

integrate(sec(d*x+c)**2/(a+I*a*tan(d*x+c))**8,x)

[Out]

Piecewise((-I*tan(c + d*x)**6*sec(c + d*x)**2/(896*a**8*d*tan(c + d*x)**8 - 7168*I*a**8*d*tan(c + d*x)**7 - 25
088*a**8*d*tan(c + d*x)**6 + 50176*I*a**8*d*tan(c + d*x)**5 + 62720*a**8*d*tan(c + d*x)**4 - 50176*I*a**8*d*ta
n(c + d*x)**3 - 25088*a**8*d*tan(c + d*x)**2 + 7168*I*a**8*d*tan(c + d*x) + 896*a**8*d) - 8*tan(c + d*x)**5*se
c(c + d*x)**2/(896*a**8*d*tan(c + d*x)**8 - 7168*I*a**8*d*tan(c + d*x)**7 - 25088*a**8*d*tan(c + d*x)**6 + 501
76*I*a**8*d*tan(c + d*x)**5 + 62720*a**8*d*tan(c + d*x)**4 - 50176*I*a**8*d*tan(c + d*x)**3 - 25088*a**8*d*tan
(c + d*x)**2 + 7168*I*a**8*d*tan(c + d*x) + 896*a**8*d) + 29*I*tan(c + d*x)**4*sec(c + d*x)**2/(896*a**8*d*tan
(c + d*x)**8 - 7168*I*a**8*d*tan(c + d*x)**7 - 25088*a**8*d*tan(c + d*x)**6 + 50176*I*a**8*d*tan(c + d*x)**5 +
 62720*a**8*d*tan(c + d*x)**4 - 50176*I*a**8*d*tan(c + d*x)**3 - 25088*a**8*d*tan(c + d*x)**2 + 7168*I*a**8*d*
tan(c + d*x) + 896*a**8*d) + 64*tan(c + d*x)**3*sec(c + d*x)**2/(896*a**8*d*tan(c + d*x)**8 - 7168*I*a**8*d*ta
n(c + d*x)**7 - 25088*a**8*d*tan(c + d*x)**6 + 50176*I*a**8*d*tan(c + d*x)**5 + 62720*a**8*d*tan(c + d*x)**4 -
 50176*I*a**8*d*tan(c + d*x)**3 - 25088*a**8*d*tan(c + d*x)**2 + 7168*I*a**8*d*tan(c + d*x) + 896*a**8*d) - 99
*I*tan(c + d*x)**2*sec(c + d*x)**2/(896*a**8*d*tan(c + d*x)**8 - 7168*I*a**8*d*tan(c + d*x)**7 - 25088*a**8*d*
tan(c + d*x)**6 + 50176*I*a**8*d*tan(c + d*x)**5 + 62720*a**8*d*tan(c + d*x)**4 - 50176*I*a**8*d*tan(c + d*x)*
*3 - 25088*a**8*d*tan(c + d*x)**2 + 7168*I*a**8*d*tan(c + d*x) + 896*a**8*d) - 120*tan(c + d*x)*sec(c + d*x)**
2/(896*a**8*d*tan(c + d*x)**8 - 7168*I*a**8*d*tan(c + d*x)**7 - 25088*a**8*d*tan(c + d*x)**6 + 50176*I*a**8*d*
tan(c + d*x)**5 + 62720*a**8*d*tan(c + d*x)**4 - 50176*I*a**8*d*tan(c + d*x)**3 - 25088*a**8*d*tan(c + d*x)**2
 + 7168*I*a**8*d*tan(c + d*x) + 896*a**8*d) + 127*I*sec(c + d*x)**2/(896*a**8*d*tan(c + d*x)**8 - 7168*I*a**8*
d*tan(c + d*x)**7 - 25088*a**8*d*tan(c + d*x)**6 + 50176*I*a**8*d*tan(c + d*x)**5 + 62720*a**8*d*tan(c + d*x)*
*4 - 50176*I*a**8*d*tan(c + d*x)**3 - 25088*a**8*d*tan(c + d*x)**2 + 7168*I*a**8*d*tan(c + d*x) + 896*a**8*d),
 Ne(d, 0)), (x*sec(c)**2/(I*a*tan(c) + a)**8, True))

Maxima [A] (verification not implemented)

none

Time = 0.21 (sec) , antiderivative size = 21, normalized size of antiderivative = 0.78 \[ \int \frac {\sec ^2(c+d x)}{(a+i a \tan (c+d x))^8} \, dx=\frac {i}{7 \, {\left (i \, a \tan \left (d x + c\right ) + a\right )}^{7} a d} \]

[In]

integrate(sec(d*x+c)^2/(a+I*a*tan(d*x+c))^8,x, algorithm="maxima")

[Out]

1/7*I/((I*a*tan(d*x + c) + a)^7*a*d)

Giac [B] (verification not implemented)

Both result and optimal contain complex but leaf count of result is larger than twice the leaf count of optimal. 189 vs. \(2 (21) = 42\).

Time = 1.21 (sec) , antiderivative size = 189, normalized size of antiderivative = 7.00 \[ \int \frac {\sec ^2(c+d x)}{(a+i a \tan (c+d x))^8} \, dx=-\frac {2 \, {\left (7 \, \tan \left (\frac {1}{2} \, d x + \frac {1}{2} \, c\right )^{13} - 42 i \, \tan \left (\frac {1}{2} \, d x + \frac {1}{2} \, c\right )^{12} - 182 \, \tan \left (\frac {1}{2} \, d x + \frac {1}{2} \, c\right )^{11} + 490 i \, \tan \left (\frac {1}{2} \, d x + \frac {1}{2} \, c\right )^{10} + 1001 \, \tan \left (\frac {1}{2} \, d x + \frac {1}{2} \, c\right )^{9} - 1484 i \, \tan \left (\frac {1}{2} \, d x + \frac {1}{2} \, c\right )^{8} - 1716 \, \tan \left (\frac {1}{2} \, d x + \frac {1}{2} \, c\right )^{7} + 1484 i \, \tan \left (\frac {1}{2} \, d x + \frac {1}{2} \, c\right )^{6} + 1001 \, \tan \left (\frac {1}{2} \, d x + \frac {1}{2} \, c\right )^{5} - 490 i \, \tan \left (\frac {1}{2} \, d x + \frac {1}{2} \, c\right )^{4} - 182 \, \tan \left (\frac {1}{2} \, d x + \frac {1}{2} \, c\right )^{3} + 42 i \, \tan \left (\frac {1}{2} \, d x + \frac {1}{2} \, c\right )^{2} + 7 \, \tan \left (\frac {1}{2} \, d x + \frac {1}{2} \, c\right )\right )}}{7 \, a^{8} d {\left (\tan \left (\frac {1}{2} \, d x + \frac {1}{2} \, c\right ) - i\right )}^{14}} \]

[In]

integrate(sec(d*x+c)^2/(a+I*a*tan(d*x+c))^8,x, algorithm="giac")

[Out]

-2/7*(7*tan(1/2*d*x + 1/2*c)^13 - 42*I*tan(1/2*d*x + 1/2*c)^12 - 182*tan(1/2*d*x + 1/2*c)^11 + 490*I*tan(1/2*d
*x + 1/2*c)^10 + 1001*tan(1/2*d*x + 1/2*c)^9 - 1484*I*tan(1/2*d*x + 1/2*c)^8 - 1716*tan(1/2*d*x + 1/2*c)^7 + 1
484*I*tan(1/2*d*x + 1/2*c)^6 + 1001*tan(1/2*d*x + 1/2*c)^5 - 490*I*tan(1/2*d*x + 1/2*c)^4 - 182*tan(1/2*d*x +
1/2*c)^3 + 42*I*tan(1/2*d*x + 1/2*c)^2 + 7*tan(1/2*d*x + 1/2*c))/(a^8*d*(tan(1/2*d*x + 1/2*c) - I)^14)

Mupad [B] (verification not implemented)

Time = 4.01 (sec) , antiderivative size = 19, normalized size of antiderivative = 0.70 \[ \int \frac {\sec ^2(c+d x)}{(a+i a \tan (c+d x))^8} \, dx=-\frac {1}{7\,a^8\,d\,{\left (\mathrm {tan}\left (c+d\,x\right )-\mathrm {i}\right )}^7} \]

[In]

int(1/(cos(c + d*x)^2*(a + a*tan(c + d*x)*1i)^8),x)

[Out]

-1/(7*a^8*d*(tan(c + d*x) - 1i)^7)